using System;
using System.Collections.Generic;
using System.Text;
using System.Xml.Serialization;

namespace SMS.Common.Entities
{
    public class Return
    {
        private string rtn_id;
        [XmlElement("ReturnId",Order=1)]
        public string Rtn_ID
        {
            get { return rtn_id; }
            set { rtn_id = value; }
        }
        private string store_id;
        [XmlElement("StoreId",Order=3)]
        public string Store_ID
        {
            get { return store_id; }
            set { store_id = value; }
        }

        private string store_name;
        [XmlIgnore]
        public string Store_Name
        {
            get { return store_name; }
            set { store_name = value; }
        }

        private string desc;
        [XmlElement("Description",Order=4)]
        public string Description
        {
            get { return desc; }
            set { desc = value; }
        }

        private string editor;
        [XmlIgnore]
        public string Editor
        {
            get { return editor; }
            set { editor = value; }
        }

        private string rtn_date;
        [XmlElement("ReturnDate",Order=2)]
        public string Return_Date
        {
            get { return rtn_date; }
            set { rtn_date = value; }
        }

        private string status;
        [XmlIgnore]
        public string Status
        {
            get { return status; }
            set { status = value; }
        }

        private string edit_date;
        [XmlIgnore]
        public string Edit_Date
        {
            get { return edit_date; }
            set { edit_date = value; }
        }

        private List<ReturnDetail> detail;
        [XmlArray("Items",Order=5),XmlArrayItem("Item")]
        public List<ReturnDetail> Details
        {
            get { return detail; }
            set { detail = value; }
        }

        public Return() { }
        public Return(string rtn_id, string store_id, string store_name, string desc, string rtn_date, string status,string editor,string edit_date, List<ReturnDetail> detail)
        {
            this.rtn_id = rtn_id;
            this.store_id = store_id;
            this.store_name = store_name;
            this.desc = desc;
            this.rtn_date = rtn_date;
            this.status = status;
            this.editor = editor;
            this.edit_date = edit_date;
            this.detail =detail;
        }
        public Return(string rtn_id, string store_id, string store_name, string desc, string rtn_date, string status,string editor,string edit_date)
        {
            this.rtn_id = rtn_id;
            this.store_id = store_id;
            this.store_name = store_name;
            this.desc = desc;
            this.rtn_date = rtn_date;
            this.status = status;
            this.editor = editor;
            this.edit_date = edit_date;
        }
    }

    public class Returns
    {
        [XmlElement("Return")]
        public Return[] rtn;
    }
}
